/**
 * 
 */
package com.cea.papyrus.diagram.statemachine.editpart;

import org.eclipse.gef.commands.Command;

/**
 * @author dumoulin
 *
 */
public class ContainerDimensionAdaptationEditPolicy extends com.cea.papyrus.core.editpart.ContainerDimensionAdaptationEditPolicy {

    /**
     * Override to disallow resizing on particular elements.
     */
    @Override
    protected Command getAdaptDimensionCommand() {
        if((getGraphNodeEditPart() instanceof StateMachineEditPart) || (getGraphNodeEditPart() instanceof RegionEditPart))
            return null;
        
        return super.getAdaptDimensionCommand();
    }
}
